Counters are essential parts of packet processing devices like routers and switches. Such packet processing devices typically contain several counters such as one counter per port, per routing entry, etc. in order to provide proper usage statistics. The number of counters is even increasing further in Openflow switches, which usually apply counters for tables and meters and where packets can match multiple flow entries in different flow tables, so that each time a counter has to be increased.
Although incrementing a counter does not seem to be difficult task at first glance, it needs a memory read to get the actual value of the counter and a memory write transaction in order to write back the new value. Memory transactions can be sped up seriously by using some cache, but only until the number of counters is not too high. However, a high number of counters is used inter alia in Openflow switches.
Using many counters is a common requirement for modern network devices. Maintaining these counters means a surprisingly high burden for the memory bus and/or cache architecture, which causes memory access speed degradation. Even in the case when there is enough cache to store all the counters, valuable cache space is taken which could be used for other purposes.